package chap2_task;
import java.util.Scanner;
public class Task4 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.print("输入一个5位整数:");
        int a=input.nextInt();
        int b1=a%10;
        int b2=a%100/10;
        int b3=a%1000/100;
        int b4=a%10000/1000;
        int b5=a/10000;
        int sum=b1+b2+b3+b4+b5;
        System.out.println("整数的每一位上数字的和=:"+sum);
    }
}
